package com.etc.entity;

import java.io.Serializable;
import java.util.Date;

public class Talk implements Serializable {
    private Integer tid;

    private String tcategory;

    private Integer tarticleid;

    private String tcontent;

    private Integer ttopicid;

    private Integer tUid;

    private Date tcreatetime;

    private Date fathertime;
    
    private User user;
    
    

    public User getUser() {
		return user;
	}

	public void setUser(User user) {
		this.user = user;
	}

	private static final long serialVersionUID = 1L;

    public Integer getTid() {
        return tid;
    }

    public void setTid(Integer tid) {
        this.tid = tid;
    }

    public String getTcategory() {
        return tcategory;
    }

    public void setTcategory(String tcategory) {
        this.tcategory = tcategory == null ? null : tcategory.trim();
    }

    public Integer getTarticleid() {
        return tarticleid;
    }

    public void setTarticleid(Integer tarticleid) {
        this.tarticleid = tarticleid;
    }

    public String getTcontent() {
        return tcontent;
    }

    public void setTcontent(String tcontent) {
        this.tcontent = tcontent == null ? null : tcontent.trim();
    }

    public Integer getTtopicid() {
        return ttopicid;
    }

    public void setTtopicid(Integer ttopicid) {
        this.ttopicid = ttopicid;
    }

    public Integer gettUid() {
        return tUid;
    }

    public void settUid(Integer tUid) {
        this.tUid = tUid;
    }

    public Date getTcreatetime() {
        return tcreatetime;
    }

    public void setTcreatetime(Date tcreatetime) {
        this.tcreatetime = tcreatetime;
    }

    public Date getFathertime() {
        return fathertime;
    }

    public void setFathertime(Date fathertime) {
        this.fathertime = fathertime;
    }
    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        Talk other = (Talk) that;
        return (this.getTid() == null ? other.getTid() == null : this.getTid().equals(other.getTid()))
            && (this.getTcategory() == null ? other.getTcategory() == null : this.getTcategory().equals(other.getTcategory()))
            && (this.getTarticleid() == null ? other.getTarticleid() == null : this.getTarticleid().equals(other.getTarticleid()))
            && (this.getTcontent() == null ? other.getTcontent() == null : this.getTcontent().equals(other.getTcontent()))
            && (this.getTtopicid() == null ? other.getTtopicid() == null : this.getTtopicid().equals(other.getTtopicid()))
            && (this.gettUid() == null ? other.gettUid() == null : this.gettUid().equals(other.gettUid()))
            && (this.getTcreatetime() == null ? other.getTcreatetime() == null : this.getTcreatetime().equals(other.getTcreatetime()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getTid() == null) ? 0 : getTid().hashCode());
        result = prime * result + ((getTcategory() == null) ? 0 : getTcategory().hashCode());
        result = prime * result + ((getTarticleid() == null) ? 0 : getTarticleid().hashCode());
        result = prime * result + ((getTcontent() == null) ? 0 : getTcontent().hashCode());
        result = prime * result + ((getTtopicid() == null) ? 0 : getTtopicid().hashCode());
        result = prime * result + ((gettUid() == null) ? 0 : gettUid().hashCode());
        result = prime * result + ((getTcreatetime() == null) ? 0 : getTcreatetime().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", tid=").append(tid);
        sb.append(", tcategory=").append(tcategory);
        sb.append(", tarticleid=").append(tarticleid);
        sb.append(", tcontent=").append(tcontent);
        sb.append(", ttopicid=").append(ttopicid);
        sb.append(", tUid=").append(tUid);
        sb.append(", tcreatetime=").append(tcreatetime);
        sb.append(", fathertime=").append(fathertime);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}